var title, coord;
document.addEventListener('plusready',function(){
	var ws = plus.webview.currentWebview();
	var id = ws.aid;
	console.log(id);
	var info = plus.storage.getItem('hosInfo');
	var ilist = $.parseJSON(info);
	$.each(ilist, function(k,v) {
		plus.nativeUI.closeWaiting();
		if(v.aid == id){
//			console.log(JSON.stringify(v));
			plus.nativeUI.closeWaiting();
			$('.title').text(v.title);
			$('.area').text(v.area);
			$('.picinfo').attr('src',webRoot+v.thumb);
			$('.address').text(v.address);  
			$('.phone').text(v.phone);
			$('.distance').text(v.distance);
			$('.conbody').html(v.introduce.replace(/src="/g ,'src="'+webRoot));
			coord = v.coord;
			title = v.title;
		}
	});
	//点击地图进入医馆位置地图显示
	$('.goMep').click(function(){
		goNewPage('home-hospital-map.html',{title:title,coord:coord})
	})
},false)
function callphone(){
	var telNum = $('.phone').text();
	plus.nativeUI.confirm('\n是否拨打医馆电话\n',function(e){
		if (e.index == 0) {
			plus.device.dial(telNum,false);
		}
	},'提示',['是','否']);
}
